@import "tailwindcss";

:root {
  --foreground-rgb: 0, 0, 0;
  --background-rgb: 255, 255, 255;
}

.dark {
  --foreground-rgb: 255, 255, 255;
  --background-rgb: 0, 0, 0;
}

body {
  color: rgb(var(--foreground-rgb));
  background: rgb(var(--background-rgb));
  height: 100%;
}

/* 确保暗黑模式正确应用到所有元素 */
html.dark {
  color-scheme: dark;
}

html.dark body {
  background-color: #000000;
  color: #ffffff;
}

/* 主内容区暗黑模式强化 */
html.dark .bg-white {
  background-color: #000000 !important;
}

html.dark .text-black {
  color: #ffffff !important;
}

html.dark .bg-gray-50 {
  background-color: #111827 !important;
}

html.dark .text-gray-700 {
  color: #d1d5db !important;
}

html.dark .text-gray-600 {
  color: #9ca3af !important;
}

html.dark .text-gray-500 {
  color: #6b7280 !important;
}

html.dark .border-gray-100 {
  border-color: #374151 !important;
}

html.dark .border-gray-800 {
  border-color: #374151 !important;
}

/* 卡片暗黑模式特别强化 */
html.dark .space-y-4 > div,
html.dark .space-y-3 > div {
  background-color: #111827 !important;
  border-color: #374151 !important;
}

html.dark .space-y-4 > div:hover,
html.dark .space-y-3 > div:hover {
  background-color: #1f2937 !important;
}

/* 侧边栏暗黑模式样式 - 更强的选择器 */
html.dark aside#mobile-sidebar {
  background-color: #000000 !important;
  border-color: #374151 !important;
}

html.dark aside#mobile-sidebar h1,
html.dark aside#mobile-sidebar p,
html.dark aside#mobile-sidebar a,
html.dark aside#mobile-sidebar span,
html.dark aside#mobile-sidebar button {
  color: #ffffff !important;
}

html.dark aside#mobile-sidebar .text-gray-600 {
  color: #9ca3af !important;
}

html.dark aside#mobile-sidebar .text-gray-500 {
  color: #6b7280 !important;
}

html.dark aside#mobile-sidebar .text-gray-400 {
  color: #9ca3af !important;
}

html.dark aside#mobile-sidebar .bg-gray-200 {
  background-color: #374151 !important;
}

html.dark aside#mobile-sidebar .bg-gray-700 {
  background-color: #4b5563 !important;
}

html.dark aside#mobile-sidebar .border-gray-100 {
  border-color: #374151 !important;
}

html.dark aside#mobile-sidebar .border-gray-800 {
  border-color: #374151 !important;
}

html.dark aside#mobile-sidebar .hover\:bg-gray-50:hover {
  background-color: #374151 !important;
}

html.dark aside#mobile-sidebar .hover\:bg-gray-800:hover {
  background-color: #4b5563 !important;
}

/* 确保链接在暗黑模式下正确显示 */
html.dark aside#mobile-sidebar a:hover {
  color: #ffffff !important;
}

/* 分类页面暗黑模式强化 */
html.dark .divide-y > li {
  border-color: #374151 !important;
}

html.dark .divide-y > li:hover {
  background-color: #1f2937 !important;
}

/* 分类页面特定样式强化 */
html.dark .bg-gray-900 {
  background-color: #111827 !important;
}

html.dark .bg-gray-800 {
  background-color: #1f2937 !important;
}

html.dark .hover\:bg-gray-50:hover {
  background-color: #1f2937 !important;
}

html.dark .hover\:bg-gray-800:hover {
  background-color: #374151 !important;
}

/* 分类选择弹窗中的标签按钮暗黑模式强化 */
html.dark .flex.flex-wrap.gap-2 button:hover,
html.dark .bg-gray-50.dark\:bg-gray-800 button:hover {
  background-color: #374151 !important;
}

/* 专门针对分类标签按钮的悬浮效果 */
html.dark button.hover\:bg-gray-100:hover {
  background-color: #374151 !important;
}

html.dark button.hover\:bg-gray-700:hover {
  background-color: #4b5563 !important;
}

/* 收藏页面提示框暗黑模式强化 */
html.dark .bg-green-50 {
  background-color: rgba(34, 197, 94, 0.1) !important;
}

html.dark .border-green-200 {
  border-color: #166534 !important;
}

html.dark .text-green-600 {
  color: #4ade80 !important;
} 